home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
PC Media 22
/
PC MEDIA CD22.iso
/
share
/
prog
/
mwdemo
/
funcs.doc
< prev
next >
Wrap
Text File
|
1994-08-05
|
17KB
|
704 lines
BC1 MetaWINDOW FUNCTION SUMMARY
All MetaWINDOW graphic libraries include the
following function set:
C2System Initialization
---------------------
CCFindBestDisplay() D- Auto detect the best
graphics hardware device mode.
CCFindBestInfo() D- Return information about
a specified device mode.
CCFindUserDisplay() D- Return display mode
based on user command line parameters.
CCFindBestMouse() D- Auto detect the best
mouse input device mode.
CCQueryGraphics() D- Auto detect the graphics
hardware configuration.
CCInitGraphics() D- Initialize the MetaWINDOW
graphics system.
CCStopGraphics() D- Terminate graphics processing.
CCMetaVersion() D- Return MetaWINDOW version number.
CCScreenRect() D- Return the screen bitmap limits.
CCSetDisplay() D- Select the visible graphics page.
CCSetBitmap() D- Select the writable graphics page.
CCRasterOp() D- Set the rasterOp drawing mode (16
standard + 16 transparent).
CCPlaneMask() D- Inhibit writing to masked bitmap
planes.
CCWaitRetrace() D- Wait for video retrace event
to occur.
C2Pen Attribute Functions
-----------------------
CCPenColor() D- Select the pen color.
CCPenSize() D- Set the pen size.
CCPenPattern() D- Select the pen pattern.
CCPenDash() D- Select dashed line style.
CCPenNormal() D- Reset to default pen attributes.
CCHidePen() D- Disable drawing operations.
CCShowPen() D- Enable drawing operations.
CCGetPenState() D- Save the current pen attributes.
CCSetPenState() D- Restore the pen attributes.
CCPenOffset() D- Set the centered-dash offset.
CCFillRule() D- Select the polygon fill rule
(winding/oddEven).
CCDashStyle() D- Select the dash style
(OnOff/Double).
CCPenCap() D- Select the thin line end-cap style.
C2Pen Attributes
--------------------------
CCPenShape() D- Select the pen shape
(rectangle/square or oval/circle).
CCPenCap() D- Select the line end-cap style
(flat/square/round).
CCPenJoin() D- Select the connected-line join style
(round/bevel/miter).
CCMiterLimit() D- Set mitered-join limit angle.
C2Background Style
----------------
CCBackPattern() D- Set background pattern.
CCBackColor() D- Set background color.
C2Point and Line Drawing Routines
-------------------------------
CCMoveTo() D- Move to (X,Y).
CCLineTo() D- Draw line to (X,Y).
CCMoveRel() D- Move relative (DX,DY).
CCLineRel() D- Draw line relative (DX,DY).
CCPolyLine() D- Draw connected multi-line sequence.
CCPolySegment() D- Draw disconnected multi-line
sequence.
CCSetPixel() D- Set pixel with the current pen
color.
CCGetPixel() D- Return color of pixel at (X,Y).
C2Rectangle Drawing Routines
--------------------------
CCFrameRect() D- Draw rectangle outline.
CCPaintRect() D- Fill rectangle interior.
CCEraseRect() D- Erase rectangle interior.
CCInvertRect() D- Invert rectangle interior.
CCFillRect() D- Fill rectangle with specified
pattern.
C2Rounded-Corner Rectangle Drawing Routines
-----------------------------------------
CCFrameRoundRect() D- Draw rounded-rectangle
outline.
CCPaintRoundRect() D- Fill rounded-rectangle
interior.
CCEraseRoundRect() D- Erase rounded-rectangle
interior.
CCInvertRoundRect() D- Invert rounded-rectangle
interior.
CCFillRoundRect() D- Fill roundRect with specified
pattern.
C2Circle/Ellipse/Oval Drawing Routines
------------------------------------
CCFrameOval() D- Draw oval outline.
CCPaintOval() D- Fill oval interior.
CCEraseOval() D- Erase oval interior.
CCInvertOval() D- Invert oval interior.
CCFillOval() D- Fill oval with specified pattern.
C2Arc and Wedge Drawing Routines
------------------------------
CCFrameArc() D- Draw arc outline.
CCPaintArc() D- Fill arc interior.
CCEraseArc() D- Erase arc interior.
CCInvertArc() D- Invert arc interior.
CCFillArc() D- Fill arc with specified pattern.
C2Polygon Drawing Routines
------------------------
CCFramePoly() D- Draw polygon outline.
CCPaintPoly() D- Fill polygon interior(s).
CCErasePoly() D- Erase polygon interior(s).
CCInvertPoly() D- Invert polygon interior(s).
CCFillPoly() D- Fill polygon(s) with specified
pattern.
CCFillPolygon() D- Optimized fill for convex,
non-convex and complex polygons.
C2Bezier Curve Drawing Routines
------------------------
CCFrameBezier() D- Draw Bezier outline.
CCPaintBezier() D- Fill Bezier interior(s).
CCEraseBezier() D- Erase Bezier interior(s).
CCInvertBezier() D- Invert Bezier interior(s).
CCFillBezier() D- Fill Bezier(s) with specified
pattern.
CCPolyBezier() D- Draw connected multi-Bezier
sequence.
C2Marker Drawing Routines
-----------------------
CCMarkerType() D- Set marker style.
CCMarkerSize() D- Set marker size.
CCMarkerAngle() D- Set marker angle.
CCPolyMarker() D- Draw marker(s).
C2Text Drawing Procedures
-----------------------
CCDrawChar() D- Draw character.
CCDrawString() D- Draw string.
CCDrawText() D- Draw text substring.
CCCharWidth() D- Return character width.
CCStringWidth() D- Return string width.
CCTextWidth() D- Return text substring width.
C2Text Drawing Procedures - International Fonts
C2(16-bit coded characters)
---------------------------------------------
CCDrawChar16() D- Draw coded character.
CCDrawString16() D- Draw coded string.
CCDrawText16() D- Draw coded text substring.
CCCharWidth16() D- Return coded character width.
CCStringWidth16() D- Return coded string width.
CCTextWidth16() D- Return coded text substring
width.
C2Font Attribute Functions
--------------------------
CCSetFont() D- Make a font the current drawing
font.
CCTextAlign() D- Set text horizontal/vertical
alignment.
CCTextFace() D- Set font facing (bold, italic,
underline,strikeout,etc.).
CCTextUnder() D- Set text underline distance.
CCTextScore() D- Set text underline scoring.
CCTextPath() D- Set text path angle.
CCTextExtra() D- Set character justification
spacing.
CCTextSpace() D- Set space justification spacing.
CCTextAngle() D- Set text rotation angle.
CCTextSize() D- Set text size.
CCTextSlant() D- Set text slant angle.
C2Image Drawing Routines
----------------------
CCImageSize() D- Calculate image buffer
requirements.
CCReadImage() D- Read bitmap into an image buffer.
CCWriteImage() D- Write image buffer to bitmap.
CCXlateImage() D- Translate image buffer to a new
bitmap format.
C2Point "In" Object Detection
--------------------------
CCPtInRect() D- Return true if point is inside a
rectangle.
CCPtInOval() D- Return true if point is inside an
oval.
CCPtInArc() D- Return true if point is inside an
arc.
CCPtInRoundRect() D- Return true if point is inside a
roundRect.
CCPtInPoly() D- Return true if point is inside a
polygon.
CCPtInFlood() D- Return true if point is inside a
flood-fill area.
CCPtInBoundary() D- Return true if point is inside a
boundary-fill area.
C2Point "On" Object Detection
--------------------------
CCPtOnLine() D- Return true if point is on a line.
CCPtOnPolyLine() D- Return true if point is on a
polyline.
CCPtOnRect() D- Determine if point is on the edge of
a rectangle.
CCPtOnOval() D- Determine if point is on the edge of
an oval.
CCPtOnArc() D- Determine if point is on the edge of
an arc.
CCPtOnRoundRect() D- Determine if point is on the
edge of a roundRect.
CCPtOnPoly() D- Determine if point is on the edge of
a polygon.
C2Graphic Inquiries
-----------------
CCQueryPosn() D- Return current (X,Y) position.
CCQueryX() D- Return current X position.
CCQueryY() D- Return current Y position.
CCQueryRes() D- Return pixel resolution (X & Y
pixels/inch).
CCQueryError() D- Return MetaWINDOW error status.
C2Custom Styles and Patterns
--------------------------
CCAlignPattern() D- Set pattern alignment.
CCDefinePattern() D- Define a custom multi-color fill
pattern.
CCDefineDash() D- Define a custom line dash style (up
to 256 pixel lengths).
C2Color Graphics
--------------
CCQueryColors() D- Return maximum display colors.
CCReadPalette() D- Read color palette.
CCWritePalette() D- Load color palette.
CCFindClosestRGB() D- Find the value in the palette
that most closely matches a given RGB color.
CCBorderColor() D- Sets the color of the screen
overscan area.
C2Operations with Bitmaps
-----------------------
CCCreateBitmap() D- Create an offscreen
bitmap in conventional, EMS, XMS or disk-cached
virtual memory.
CCDestroyBitmap() D- Release an offscreen
bitmap created by CreateBitmap().
CCInitBitmap() D- Initialize a display,
local-memory, EMS - XMS or disk-cached
virtual bitmap.
CCCloseBitmap() D- Release a display, local-memory,
EMS - XMS or disk-cached virtual bitmap.
CCPortBitmap() D- Assign bitmap to the current port.
CCCopyBlit() D- Copy an image between two bitmaps.
CCScrollRect() D- Move an image to a new position on
the same bitmap.
CCCursorBitmap() D- Set active bitmap for cursor
tracking.
CCZoomBlit() D- Copy a scaled image between two
bitmaps.
C2Operations with Ports & Windows
-------------------------------
CCInitPort() D- Initialize a new port/window.
CCGetPort() D- Return pointer to the current port.
CCSetPort() D- Make specified port the current port.
CCPortSize() D- Set the port size.
CCMovePortTo() D- Set the port location.
CCSetOrigin() D- Set the local port coordinate
origin.
CCPortOrigin() D- Set the origin orientation
(upperleft/lowerleft).
CCVirtualRect() D- Set the port's virtual coordinate
limits.
CCSetLocal() D- Set port to local coordinates.
CCSetVirtual() D- Set port to virtual coordinates.
CCClipRect() D- Set the port clipping rectangle.
CCClipRegion() D- Set clipping to an irregular shaped
region.
C2Operations with Regions
-----------------------
CCBitmapToRegion() D- Create a region from a bitmap
and given transparent color.
CCOpenRegion() D- Open to create a new region from
drawing calls.
CCCloseRegion() D- Closes OpenRegion() drawing
calls.
CCDestroyRegion() D- Release region.
CCDupRegion() D- Creates a duplicate of an existing
region.
CCRectRegion() D- Creates a rectangle shaped region.
CCRectListToRegion() D- Converts a list of rectangles
to a region.
CCIntersectRegion() D- Creates a region that is the
intersection of two regions.
CCSubtractRegion() D- Creates a region that is the
area of one region with a second region
subtracted from it.
CCUnionRegion() D- Creates a region that is the
combination of two regions.
CCXorRegion() D- Creates a region that is the area of
one region or other, but not both.
C2Calculations and Tests with Regions
-----------------------------------
CCEmptyRegion() D- Determine if a region is a NULL
region with no area
CCNullRegion() D- Sets a region to an empty region.
CCOffsetRegion() D- Move the position of a region.
CCPtInRegion() D- Determines if a point is located
within a region.
CCRectInRegion() D- Determines if a rectangle
intersects a region.
C2Drawing Functions with Regions
------------------------------
CCEraseRegion() D- Fills a region with the current
background pattern.
CCFillRegion() D- Fills a region with a specified
pattern.
CCInvertRegion() D- Inverts the colors within a
region.
CCPaintRegion() D- Fills a region using the current
foreground pattern & rasterOp
C2Clipping Operations with Regions
--------------------------------
CCClipRegion() D- Set clipping to an irregular shaped
region.
C2Calculations with Points
--------------------------
CCSetPt() D- Copy X,Y to a point variable.
CCDupPt() D- Copy a point variable to another point
variable.
CCAddPt() D- Add two point variables.
CCSubPt() D- Subtract two point variables.
CCEqualPt() D- Return true if two points are equal.
CCScalePt() D- Scale a point variable.
CCMapPt() D- Translate and scale a point variable.
CCOvalPt() D- Return the point on oval at a specified
angle.
CCPtToAngle() D- Return angle from oval center to a
point.
C2Calculations with Rectangles
----------------------------
CCSetRect() D- Copy coordinates to a rectangle
variable.
CCDupRect() D- Copy a rect variable to another rect
variable.
CCPt2Rect() D- Copy diagonal points to a rectangle
variable.
CCCenterRect() D- Calculate a centered rectangle
variable.
CCOffsetRect() D- Offset a rectangle variable.
CCInsetRect() D- Inset or outset a rectangle
variable.
CCInceptRect() D- Return intersect rect of two
rectangles.
CCUnionRect() D- Return union rect of two
rectangles.
CCEqualRect() D- Return true if two rectangles are
equal.
CCShiftRect() D- Return voided rect(s) of a shifted
rect move.
CCMapRect() D- Translate and scale a rectangle
variable.
C2Calculations with Polygons
--------------------------
CCOffsetPoly() D- Offset polygon coordinates.
CCMapPoly() D- Translate and scale polygon
coordinates.
C2Coordinate Transformations
--------------------------
CCGbl2LclPt() D- Transform point, global to local.
CCGbl2VirPt() D- Transform point, global to virtual.
CCLcl2GblPt() D- Transform point, local to global.
CCLcl2VirPt() D- Transform point, local to virtual.
CCVir2GblPt() D- Transform point, virtual to global.
CCVir2LclPt() D- Transform point, virtual to local.
CCGbl2LclRect() D- Transform rectangle, global to
local.
CCGbl2VirRect() D- Transform rectangle, global to
virtual.
CCLcl2GblRect() D- Transform rectangle, local to
global.
CCLcl2VirRect() D- Transform rectangle, local to
virtual.
CCVir2GblRect() D- Transform rectangle, virtual to
global.
CCVir2LclRect() D- Transform rectangle, virtual to
local.
C2Mouse/Digitizer/TouchScreen/Tablet/Pen Tracking
-----------------------------------------------
CCQueryMouse() D- Locate mouse/locator input
devices.
CCInitMouse() D- Initialize mouse or joystick
device tracking.
CCStopMouse() D- Terminate tracking.
CCReadMouse() D- Read position and buttons.
CCLimitMouse() D- Set tracking limits.
CCScaleMouse() D- Set tracking scale.
C2Cursor Tracking Procedures
--------------------------
CCDefineCursor() D- Define cursor style (up to 32x32
pixels in size).
CCCursorColor() D- Select cursor colors.
CCShowCursor() D- Display screen cursor.
CCHideCursor() D- Remove screen cursor.
CCMoveCursor() D- Move cursor to X,Y.
CCCursorStyle() D- Select cursor appearance.
CCTrackCursor() D- Enable asynchronous auto-cursor
tracking.
CCProtectRect() D- Define a cursor protected area.
CCProtectOff() D- Disable cursor protected areas.
CCQueryCursor() D- Return cursor position and
buttons.
CCDefineCursor() D- Define custom cursor style.
C2Event Queue Processing Procedures
---------------------------------
CCEventQueue() D- Enable event queue processing.
CCStopEvent() D- Terminate event queue processing.
CCKeyEvent() D- Retrieve next queued event.
CCPeekEvent() D- Examine queued events.
CCStoreEvent() D- Store a program generated event.
CCEventMask() D- Select events to be stored into the
event-queue.
C2File I/O Procedures
-------------------
CCFileQuery() D- Retrieve file directory info.
CCFileLoad() D- Load a (font) file into memory.
CCFileStore() D- Write a file from memory.
CCResrcQuery() D- Retrieve file directory info
from the current METAPATH and PATH settings.
CCResrcLoad() D- Load a file into memory
from the current METAPATH and PATH settings.
C2System Utilities
----------------
CCPushGrafix() D- Push the graphics state.
CCPopGrafix() D- Pop the graphics state.
CCHardCopy() D- Output an area of a screen,
local-memory, EMS, XMS or disk-cached virtual
bitmap to a dot matrix printer, laser printer or
disk file.